﻿<%@ Page Title="" Language="vb" AutoEventWireup="false" MasterPageFile="~/Site.Master" CodeBehind="list.aspx.vb" Inherits="Assignment_2___Prototype.list" %>
<%@ Register assembly="AjaxControlToolkit" namespace="AjaxControlToolkit" tagprefix="asp" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
    <style type="text/css">
        .transparent
        {}
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

    <br />

    &nbsp;
    <td width="10%">
        <a href="../RSS.aspx"><img class="RSSlogo" src="Images/rss.png" /></a>
    </td>

    
    <br />
    <br />
&nbsp;&nbsp;

    
    <asp:Button ID="btn_SearchbyParrot" runat="server" CssClass="buttons" 
        style="margin-left: 411px" Text="Search by Parrot" Width="180px" />

    
    <asp:Button ID="btn_SearchbyAttributes" runat="server" CssClass="buttons" 
        style="margin-left: 9px" Text="Search by Attributes" Width="180px" />

        <br />

        <br />

        <br />






    <asp:GridView ID="GridView1" runat="server" AllowSorting="True" 
            AutoGenerateColumns="False" DataSourceID="SqlDataSource1" 

            Width="638px" CssClass="transparent"  
            PagerStyle-CssClass="pgr"  
            AlternatingRowStyle-CssClass="alt" Height="38px" AllowPaging="True" 
            CellPadding="4" HorizontalAlign="Center" PageSize="10" ForeColor="#333333" 
            GridLines="None">

            <AlternatingRowStyle CssClass="alt" ></AlternatingRowStyle>

            <EditRowStyle BackColor="#999999" />
            <FooterStyle BackColor="#5D7B9D" ForeColor="White" Font-Bold="True" />
            <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
            <PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
            <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
            <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
            <SortedAscendingCellStyle BackColor="#E9E7E2" />
            <SortedAscendingHeaderStyle BackColor="#506C8C" />
            <SortedDescendingCellStyle BackColor="#FFFDF8" />
            <SortedDescendingHeaderStyle BackColor="#6F8DAE" />






        <Columns>
            <asp:BoundField DataField="Species" HeaderText="Species" 
                SortExpression="Species" >
            </asp:BoundField>
            <asp:BoundField DataField="Breed" HeaderText="Breed" 
                SortExpression="Breed" >
            </asp:BoundField>

            <asp:TemplateField HeaderText="Picture">
            
            <ItemTemplate>
                    <asp:HyperLink ID="HyperLink10" runat="server" NavigateUrl='<%# Eval("ParrotID", "~/Details.aspx?ParrotID={0}") %>'>
                    <asp:Image CssClass="parrotImage"  ID="Image1" runat="server" ImageUrl='<%# Eval("Picture") %>' />
                    </asp:HyperLink>
                </ItemTemplate>
            </asp:TemplateField>
            <asp:HyperLinkField HeaderText="Rating" Text="Rate : " />
        </Columns>

    </asp:GridView>

    <br />

    <asp:Button ID="btn_AddItem" runat="server" Text="Add New Parrot!" CssClass="buttons" 
        Height="35px" Width="155px"/>

    <br />

    
    <br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;

    <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
        ConnectionString="<%$ ConnectionStrings:ConnectionString %>" 
        ProviderName="<%$ ConnectionStrings:ConnectionString.ProviderName %>" 
        SelectCommand="SELECT [Species], [Breed], [Picture], [ParrotID] FROM [Parrot]"></asp:SqlDataSource>

    </asp:Content>
